// Copyright (c) Facebook, Inc. and its affiliates.
// All rights reserved.
//
// Copyright 2019 Google LLC
//
// This source code is licensed under the BSD-style license found in the
// LICENSE file in the root directory of this source tree.
//
// Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#pragma once

// ShuffleNet v1 with 1 group.
static void ShuffleNetV1G1(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /******************* Stage 2: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 36});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 36, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 36, 120});
  /******************* Stage 2: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 144, 36});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 36, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 36, 144});
  /******************* Stage 3: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 144, 72});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 72, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 72, 144});
  /******************* Stage 3: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 288, 72});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 72, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 72, 288});
  /******************* Stage 4: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 288, 144});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 144, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 144, 288});
  /******************* Stage 4: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 576, 144});
  b->Args({1, 7, 7, 3, 3, 2, 2, 2, 1, 144, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 144, 576});
}

// ShuffleNet v1 with 2 groups.
static void ShuffleNetV1G2(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /******************* Stage 2: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 50});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 50, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 2, 25, 88});
  /******************* Stage 2: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 2, 100, 25});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 50, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 2, 25, 100});
  /******************* Stage 3: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 2, 100, 50});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 100, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 2, 50, 100});
  /******************* Stage 3: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 2, 200, 50});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 100, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 2, 50, 200});
  /******************* Stage 4: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 2, 200, 100});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 200, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 2, 100, 200});
  /******************* Stage 4: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 2, 400, 100});
  b->Args({1, 7, 7, 3, 3, 2, 2, 2, 1, 200, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 2, 100, 400});
}

// ShuffleNet v1 with 3 groups.
static void ShuffleNetV1G3(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /******************* Stage 2: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 60});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 60, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 3, 20, 72});
  /******************* Stage 2: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 3, 80, 20});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 60, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 3, 20, 80});
  /******************* Stage 3: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 3, 80, 40});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 120, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 3, 40, 80});
  /******************* Stage 3: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 3, 160, 40});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 120, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 3, 40, 160});
  /******************* Stage 4: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 3, 160, 80});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 240, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 3, 80, 160});
  /******************* Stage 4: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 3, 320, 80});
  b->Args({1, 7, 7, 3, 3, 2, 2, 2, 1, 240, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 3, 80, 320});
}

// ShuffleNet v1 with 4 groups.
static void ShuffleNetV1G4(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /******************* Stage 2: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 68});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 68, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 4, 17, 62});
  /******************* Stage 2: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 4, 68, 17});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 68, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 4, 17, 68});
  /******************* Stage 3: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 4, 68, 34});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 136, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 4, 34, 68});
  /******************* Stage 3: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 4, 136, 34});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 136, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 4, 34, 136});
  /******************* Stage 4: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 4, 136, 68});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 272, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 4, 68, 136});
  /******************* Stage 4: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 4, 272, 68});
  b->Args({1, 7, 7, 3, 3, 2, 2, 2, 1, 272, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 4, 68, 272});
}

// ShuffleNet v1 with 8 groups.
static void ShuffleNetV1G8(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /******************* Stage 2: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 96});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 96, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 8, 12, 45});
  /******************* Stage 2: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 8, 48, 12});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 96, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 8, 12, 48});
  /******************* Stage 3: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 8, 48, 24});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 192, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 8, 24, 48});
  /******************* Stage 3: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 8, 96, 24});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 192, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 8, 24, 96});
  /******************* Stage 4: stride-2 unit ******************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 8, 96, 48});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 384, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 8, 48, 96});
  /******************* Stage 4: stride-1 units *****************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 8, 192, 48});
  b->Args({1, 7, 7, 3, 3, 2, 2, 2, 1, 384, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 8, 48, 192});
}

// ShuffleNet v2 (0.5X scale)
static void ShuffleNetV2X05(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /************************** Stage 2 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 24, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 24});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 24});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 24, 1, 1});
  /************************** Stage 3 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 48, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 48, 48});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 48, 48});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 48, 1, 1});
  /************************** Stage 4 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 96, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 96, 96});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 96, 96});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 96, 1, 1});
  /*************************** Conv 5 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 192, 1024});
}

// ShuffleNet v2 (1.0X scale)
static void ShuffleNetV2X10(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /************************** Stage 2 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 24, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 58});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 58});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 58, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 58, 58});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 58, 1, 1});
  /************************** Stage 3 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 116, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 116, 116});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 116, 116});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 116, 1, 1});
  /************************** Stage 4 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 232, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 232, 232});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 232, 232});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 232, 1, 1});
  /*************************** Conv 5 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 464, 1024});
}

// ShuffleNet v2 (1.5X scale)
static void ShuffleNetV2X15(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /************************** Stage 2 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 24, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 88});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 88});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 88, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 88, 88});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 88, 1, 1});
  /************************** Stage 3 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 176, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 176, 176});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 176, 176});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 176, 1, 1});
  /************************** Stage 4 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 352, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 352, 352});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 352, 352});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 352, 1, 1});
  /*************************** Conv 5 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 704, 1024});
}

// ShuffleNet v2 (2.0X scale)
static void ShuffleNetV2X20(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*************************** Conv 1 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 24});
  /************************** Stage 2 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 24, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 122});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 122});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 122, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 122, 122});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 122, 1, 1});
  /************************** Stage 3 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 244, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 244, 244});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 244, 244});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 244, 1, 1});
  /************************** Stage 4 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 488, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 488, 488});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 488, 488});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 488, 1, 1});
  /*************************** Conv 5 **************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 976, 2048});
}

static void MobileNetV1(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D    G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 32});
  b->Args({1, 112, 112, 3, 3, 2, 2, 1, 1, 32, 1, 1});
  b->Args({1, 112, 112, 1, 1, 0, 0, 1, 1, 1, 32, 64});
  b->Args({1, 112, 112, 3, 3, 2, 2, 2, 1, 64, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 64, 128});
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 128, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 128, 128});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 128, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 128, 256});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 256, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 256, 256});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 256, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 256, 512});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 512, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 512, 512});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 512, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 512, 1024});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 1024, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 1024, 1024});
}

static void MobileNetV2(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 32});

  /************************ Bottleneck 1 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  b->Args({1, 112, 112, 3, 3, 2, 2, 1, 1, 32, 1, 1});
  b->Args({1, 112, 112, 1, 1, 0, 0, 1, 1, 1, 32, 16});

  /************************ Bottleneck 2 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  b->Args({1, 112, 112, 1, 1, 0, 0, 1, 1, 1, 16, 96});
  b->Args({1, 112, 112, 3, 3, 2, 2, 2, 1, 96, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 96, 24});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 144});
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 144, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 144, 24});

  /************************ Bottleneck 3 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  // b->Args({1,  56,  56,  1,  1,  0,  0, 1, 1,   1,   24,  144});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 144, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 144, 32});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 32, 192});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 192, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 192, 32});
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1,   1,   32,  192});
  // b->Args({1,  28,  28,  3,  3,  2,  2, 1, 1, 192,    1,    1});
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1,   1,  192,   32});

  /************************ Bottleneck 4 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1,   1,   32,  192});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 192, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 192, 64});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 64, 384});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 384, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 384, 64});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   64,  384});
  // b->Args({1,  14,  14,  3,  3,  2,  2, 1, 1, 384,    1,    1});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  384,   64});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   64,  384});
  // b->Args({1,  14,  14,  3,  3,  2,  2, 1, 1, 384,    1,    1});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  384,   64});

  /************************ Bottleneck 5 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   64,  384});
  // b->Args({1,  14,  14,  3,  3,  2,  2, 1, 1, 384,    1,    1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 384, 96});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 96, 576});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 576, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 576, 96});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   96,  576});
  // b->Args({1,  14,  14,  3,  3,  2,  2, 1, 1, 576,    1,    1});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  576,   96});

  /************************ Bottleneck 6 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   96,  576});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 576, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 576, 160});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 160, 960});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 960, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 960, 160});
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  160,  960});
  // b->Args({1,   7,   7,  3,  3,  2,  2, 1, 1, 960,    1,    1});
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  960,  160});

  /************************ Bottleneck 7 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  160,  960});
  // b->Args({1,   7,   7,  3,  3,  2,  2, 1, 1, 960,    1,    1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 960, 320});

  /******************** Pre-pooling Conv2D *********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 320, 1280});
  /******************** Post-pooling Conv2D ********************/
  /*       N   H    W   KH  KW  PH  PW  S  D    G  GCin  GCout */
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1280, 1000});
}

static void MobileNetV3Small(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*********************** Initial Stage ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 16});
  /*********************** Bottleneck 1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 112, 112, 3, 3, 2, 2, 2, 1, 16, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 16, 8});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 8, 16});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 16, 16});
  /*********************** Bottleneck 2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 16, 72});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 72, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 72, 24});
  /*********************** Bottleneck 3 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 88});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 88, 1, 1});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 88, 24});
  /*********************** Bottleneck 4 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 24, 96});
  b->Args({1, 28, 28, 5, 5, 4, 4, 2, 1, 96, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 96, 24});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 24, 96});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 96, 40});
  /*********************** Bottleneck 5 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 40, 240});
  b->Args({1, 14, 14, 5, 5, 4, 4, 1, 1, 240, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 240, 64});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 64, 240});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 240, 40});
  /*********************** Bottleneck 6 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   40,  240});
  // b->Args({1,  14,  14,  5,  5,  4,  4, 1, 1, 240,    1,    1});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  240,   64});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,   64,  240});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  240,   40});
  /*********************** Bottleneck 7 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 40, 120});
  b->Args({1, 14, 14, 5, 5, 4, 4, 1, 1, 120, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 120, 32});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 32, 120});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 120, 48});
  /*********************** Bottleneck 8 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 48, 144});
  b->Args({1, 14, 14, 5, 5, 4, 4, 1, 1, 144, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 144, 40});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 40, 144});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 144, 48});
  /*********************** Bottleneck 9 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 48, 288});
  b->Args({1, 14, 14, 5, 5, 4, 4, 2, 1, 288, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 288, 72});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 72, 288});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 288, 96});
  /*********************** Bottleneck 10 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 96, 576});
  b->Args({1, 7, 7, 5, 5, 4, 4, 1, 1, 576, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 576, 144});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 144, 576});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 576, 96});
  /*********************** Bottleneck 11 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,   96,  576});
  // b->Args({1,   7,   7,  5,  5,  4,  4, 1, 1, 576,    1,    1});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  576,  144});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  144,  576});
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  576,   96});
  /************************ Last Stage  ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,   96,  576});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 576, 1024});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1024, 1001});
}

static void MobileNetV3Large(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*********************** Initial Stage ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 16});
  /*********************** Bottleneck 1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 112, 112, 3, 3, 2, 2, 1, 1, 16, 1, 1});
  b->Args({1, 112, 112, 1, 1, 0, 0, 1, 1, 1, 16, 16});
  /*********************** Bottleneck 2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 112, 112, 1, 1, 0, 0, 1, 1, 1, 16, 64});
  b->Args({1, 112, 112, 3, 3, 2, 2, 2, 1, 64, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 64, 24});
  /*********************** Bottleneck 3 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 24, 72});
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 72, 1, 1});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 72, 24});
  /*********************** Bottleneck 4 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,  56,  56,  1,  1,  0,  0, 1, 1,   1,   24,   72});
  b->Args({1, 56, 56, 5, 5, 4, 4, 2, 1, 72, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 72, 24});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 24, 72});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 72, 40});
  /*********************** Bottleneck 5 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 40, 120});
  b->Args({1, 28, 28, 5, 5, 4, 4, 1, 1, 120, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 120, 32});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 32, 120});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 120, 40});
  /*********************** Bottleneck 6 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1,   1,   40,  120});
  // b->Args({1,  28,  28,  5,  5,  4,  4, 1, 1, 120,    1,    1});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  120,   32});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,   32,  120});
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1,   1,  120,   40});
  /*********************** Bottleneck 7 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 40, 240});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 240, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 240, 80});
  /*********************** Bottleneck 8 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 80, 200});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 200, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 200, 80});
  /*********************** Bottleneck 9 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 80, 184});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 184, 1, 1});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 184, 80});
  /********************** Bottleneck 10 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,   80,  184});
  // b->Args({1,  14,  14,  3,  3,  2,  2, 1, 1, 184,    1,    1});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  184,   80});
  /********************** Bottleneck 11 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 80, 480});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 480, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 480, 120});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 120, 480});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 480, 112});
  /********************** Bottleneck 12 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 112, 672});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 672, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 672, 168});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 168, 672});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 672, 112});
  /********************** Bottleneck 13 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1,   1,  112,  672});
  b->Args({1, 14, 14, 5, 5, 4, 4, 2, 1, 672, 1, 1});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 672, 160});
  /********************** Bottleneck 14 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 160, 960});
  b->Args({1, 7, 7, 5, 5, 4, 4, 1, 1, 960, 1, 1});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 960, 240});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 240, 960});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 960, 160});
  /********************** Bottleneck 15 ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  160,  960});
  // b->Args({1,   7,   7,  5,  5,  4,  4, 1, 1, 960,    1,    1});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  960,  240});
  // b->Args({1,   1,   1,  1,  1,  0,  0, 1, 1,   1,  240,  960});
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  960,  160});
  /************************ Last Stage  ***********************/
  /*       N   H    W   KH  KW  PH  PW  S  D   G   GCin  GCout */
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1,   1,  160,  960});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 960, 1280});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1280, 1001});
}

// SqueezeNet 1.0
static void SqueezeNetV10(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /************************** Conv 1 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 224, 224, 7, 7, 6, 6, 2, 1, 1, 3, 96});
  /************************** Fire 2 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 96, 16});
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 16, 64});
  b->Args({1, 55, 55, 3, 3, 2, 2, 1, 1, 1, 16, 64});
  /************************** Fire 3 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 56, 55, 1, 1, 0, 0, 1, 1, 1, 128, 16});
  // b->Args({1,  55,  55,  1,  1,  0,  0, 1, 1, 1,   16,   64});
  // b->Args({1,  55,  55,  3,  3,  2,  2, 1, 1, 1,   16,   64});
  /************************** Fire 4 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 128, 32});
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 32, 128});
  b->Args({1, 55, 55, 3, 3, 2, 2, 1, 1, 1, 32, 128});
  /************************** Fire 5 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 256, 32});
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 32, 128});
  b->Args({1, 27, 27, 3, 3, 2, 2, 1, 1, 1, 32, 128});
  /************************** Fire 6 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 256, 48});
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 48, 192});
  b->Args({1, 27, 27, 3, 3, 2, 2, 1, 1, 1, 48, 192});
  /************************** Fire 7 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 384, 48});
  // b->Args({1,  27,  27,  1,  1,  0,  0, 1, 1, 1,   48,  192});
  // b->Args({1,  27,  27,  3,  3,  2,  2, 1, 1, 1,   48,  192});
  /************************** Fire 8 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 384, 64});
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 64, 256});
  b->Args({1, 27, 27, 3, 3, 2, 2, 1, 1, 1, 64, 256});
  /************************** Fire 9 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 512, 64});
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 64, 256});
  b->Args({1, 13, 13, 3, 3, 2, 2, 1, 1, 1, 64, 256});
  /************************* Conv 10 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 512, 1000});
}

// SqueezeNet 1.1
static void SqueezeNetV11(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /************************** Conv 1 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 2, 1, 1, 3, 64});
  /************************** Fire 2 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 64, 16});
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 16, 64});
  b->Args({1, 55, 55, 3, 3, 2, 2, 1, 1, 1, 16, 64});
  /************************** Fire 3 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 55, 55, 1, 1, 0, 0, 1, 1, 1, 128, 16});
  // b->Args({1,  55,  55,  1,  1,  0,  0, 1, 1, 1,   16,   64});
  // b->Args({1,  55,  55,  3,  3,  2,  2, 1, 1, 1,   16,   64});
  /************************** Fire 4 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 128, 32});
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 32, 128});
  b->Args({1, 27, 27, 3, 3, 2, 2, 1, 1, 1, 32, 128});
  /************************** Fire 5 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 27, 27, 1, 1, 0, 0, 1, 1, 1, 256, 32});
  // b->Args({1,  27,  27,  1,  1,  0,  0, 1, 1, 1,   32,  128});
  // b->Args({1,  27,  27,  3,  3,  2,  2, 1, 1, 1,   32,  128});
  /************************** Fire 6 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 256, 48});
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 48, 192});
  b->Args({1, 13, 13, 3, 3, 2, 2, 1, 1, 1, 48, 192});
  /************************** Fire 7 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 384, 48});
  // b->Args({1,  13,  13,  1,  1,  0,  0, 1, 1, 1,   48,  192});
  // b->Args({1,  13,  13,  3,  3,  2,  2, 1, 1, 1,   48,  192});
  /************************** Fire 8 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 384, 64});
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 64, 256});
  b->Args({1, 13, 13, 3, 3, 2, 2, 1, 1, 1, 64, 256});
  /************************** Fire 9 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 512, 64});
  // b->Args({1,  13,  13,  1,  1,  0,  0, 1, 1, 1,   64,  256});
  // b->Args({1,  13,  13,  3,  3,  2,  2, 1, 1, 1,   64,  256});
  /************************* Conv 10 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 13, 13, 1, 1, 0, 0, 1, 1, 1, 512, 1000});
}

static void InceptionV3(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 299, 299, 3, 3, 0, 0, 2, 1, 1, 3, 32});
  b->Args({1, 149, 149, 3, 3, 0, 0, 1, 1, 1, 32, 32});
  b->Args({1, 147, 147, 3, 3, 2, 2, 1, 1, 1, 32, 64});
  b->Args({1, 73, 73, 1, 1, 0, 0, 1, 1, 1, 64, 80});
  b->Args({1, 73, 73, 3, 3, 0, 0, 1, 1, 1, 80, 192});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 192, 64});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 192, 48});
  b->Args({1, 35, 35, 5, 5, 4, 4, 1, 1, 1, 48, 64});
  b->Args({1, 35, 35, 3, 3, 2, 2, 1, 1, 1, 64, 96});
  b->Args({1, 35, 35, 3, 3, 2, 2, 1, 1, 1, 96, 96});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 192, 32});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 256, 64});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 256, 48});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 288, 64});
  b->Args({1, 35, 35, 1, 1, 0, 0, 1, 1, 1, 288, 48});
  b->Args({1, 35, 35, 3, 3, 0, 0, 2, 1, 1, 288, 384});
  b->Args({1, 35, 35, 3, 3, 0, 0, 2, 1, 1, 96, 96});
  b->Args({1, 17, 17, 1, 1, 0, 0, 1, 1, 1, 768, 192});
  b->Args({1, 17, 17, 1, 1, 0, 0, 1, 1, 1, 768, 128});
  b->Args({1, 17, 17, 1, 7, 0, 6, 1, 1, 1, 128, 128});
  b->Args({1, 17, 17, 7, 1, 6, 0, 1, 1, 1, 128, 192});
  b->Args({1, 17, 17, 7, 1, 6, 0, 1, 1, 1, 128, 128});
  b->Args({1, 17, 17, 1, 7, 0, 6, 1, 1, 1, 128, 192});
  b->Args({1, 17, 17, 1, 1, 0, 0, 1, 1, 1, 768, 160});
  b->Args({1, 17, 17, 1, 7, 0, 6, 1, 1, 1, 160, 160});
  b->Args({1, 17, 17, 7, 1, 6, 0, 1, 1, 1, 160, 192});
  b->Args({1, 17, 17, 7, 1, 6, 0, 1, 1, 1, 160, 160});
  b->Args({1, 17, 17, 1, 7, 0, 6, 1, 1, 1, 160, 192});
  b->Args({1, 17, 17, 1, 7, 0, 6, 1, 1, 1, 192, 192});
  b->Args({1, 17, 17, 7, 1, 6, 0, 1, 1, 1, 192, 192});
  b->Args({1, 17, 17, 3, 3, 0, 0, 2, 1, 1, 192, 320});
  b->Args({1, 17, 17, 3, 3, 0, 0, 2, 1, 1, 192, 192});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 1280, 320});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 1280, 384});
  b->Args({1, 8, 8, 1, 3, 0, 2, 1, 1, 1, 384, 384});
  b->Args({1, 8, 8, 3, 1, 2, 0, 1, 1, 1, 384, 384});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 1280, 448});
  b->Args({1, 8, 8, 3, 3, 2, 2, 1, 1, 1, 448, 384});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 1280, 192});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 2048, 320});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 2048, 384});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 2048, 448});
  b->Args({1, 8, 8, 1, 1, 0, 0, 1, 1, 1, 2048, 192});
  b->Args({1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 2048, 1001});
}

static void ResNet18(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /************************* Conv 1 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 224, 224, 7, 7, 6, 6, 2, 1, 1, 3, 64});
  /************************ Conv 2.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 1, 64, 64});
  /************************ Conv 3.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 1, 64, 128});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 1, 128, 128});
  b->Args({1, 56, 56, 1, 1, 0, 0, 2, 1, 1, 64, 128});
  /************************ Conv 4.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 1, 128, 256});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 1, 256, 256});
  b->Args({1, 28, 28, 1, 1, 0, 0, 2, 1, 1, 128, 256});
  /************************ Conv 5.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 1, 256, 512});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 1, 512, 512});
  b->Args({1, 14, 14, 1, 1, 0, 0, 2, 1, 1, 256, 512});
}

static void ResNet50(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /************************* Conv 1 *************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 224, 224, 7, 7, 6, 6, 2, 1, 1, 3, 64});
  /************************ Conv 2.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 64, 64});
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 1, 64, 64});
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 64, 256});
  // b->Args({1,  56,  56,  1,  1,  0,  0, 1, 1, 1,   64,  256});
  /************************ Conv 2.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 256, 64});
  // b->Args({1,  56,  56,  3,  3,  2,  2, 1, 1, 1,   64,   64});
  // b->Args({1,  56,  56,  1,  1,  0,  0, 1, 1, 1,   64,  256});
  /************************ Conv 3.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 256, 128});
  b->Args({1, 56, 56, 3, 3, 2, 2, 2, 1, 1, 128, 128});
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 128, 512});
  b->Args({1, 56, 56, 1, 1, 0, 0, 2, 1, 1, 256, 512});
  /************************ Conv 3.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 512, 128});
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 1, 128, 128});
  // b->Args({1,  28,  28,  1,  1,  0,  0, 1, 1, 1,  128,  512});
  /************************ Conv 4.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 512, 256});
  b->Args({1, 28, 28, 3, 3, 2, 2, 2, 1, 1, 256, 256});
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 256, 1024});
  b->Args({1, 28, 28, 1, 1, 0, 0, 2, 1, 1, 512, 1024});
  /************************ Conv 4.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 1024, 256});
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 1, 256, 256});
  // b->Args({1,  14,  14,  1,  1,  0,  0, 1, 1, 1,  256, 1024});
  /************************ Conv 5.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 1024, 512});
  b->Args({1, 14, 14, 3, 3, 2, 2, 2, 1, 1, 512, 512});
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 512, 2048});
  b->Args({1, 14, 14, 1, 1, 0, 0, 2, 1, 1, 1024, 2048});
  /************************ Conv 5.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G GCin  GCout */
  b->Args({1, 7, 7, 1, 1, 0, 0, 1, 1, 1, 2048, 512});
  b->Args({1, 7, 7, 3, 3, 2, 2, 1, 1, 1, 512, 512});
  // b->Args({1,   7,   7,  1,  1,  0,  0, 1, 1, 1,  512, 2048});
}

static void VGG(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /************************* Conv 1.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 1, 1, 1, 3, 64});
  /************************* Conv 1.2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 224, 224, 3, 3, 2, 2, 1, 1, 1, 64, 64});

  /************************* Conv 2.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 112, 112, 3, 3, 2, 2, 1, 1, 1, 64, 128});
  /************************* Conv 2.2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 112, 112, 3, 3, 2, 2, 1, 1, 1, 128, 128});

  /************************* Conv 3.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 1, 128, 256});
  /************************* Conv 3.2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 56, 56, 3, 3, 2, 2, 1, 1, 1, 256, 256});
  /************************* Conv 3.3 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 56, 56, 1, 1, 0, 0, 1, 1, 1, 256, 256});

  /************************* Conv 4.1 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 1, 256, 512});
  /************************* Conv 4.2 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 28, 28, 3, 3, 2, 2, 1, 1, 1, 512, 512});
  /************************* Conv 4.3 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 28, 28, 1, 1, 0, 0, 1, 1, 1, 512, 512});

  /************************* Conv 5.X ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 14, 14, 3, 3, 2, 2, 1, 1, 1, 512, 512});
  /************************* Conv 5.3 ************************/
  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 14, 14, 1, 1, 0, 0, 1, 1, 1, 512, 512});
}

// SRCNN (9-1-5)
static void SRCNN915(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 384, 384, 9, 9, 0, 0, 1, 1, 1, 1, 64});
  b->Args({1, 376, 376, 1, 1, 0, 0, 1, 1, 1, 64, 32});
  b->Args({1, 376, 376, 5, 5, 0, 0, 1, 1, 1, 32, 1});
}

// SRCNN (9-3-5)
static void SRCNN935(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 384, 384, 9, 9, 0, 0, 1, 1, 1, 1, 64});
  b->Args({1, 376, 376, 3, 3, 0, 0, 1, 1, 1, 64, 32});
  b->Args({1, 374, 374, 5, 5, 0, 0, 1, 1, 1, 32, 1});
}

// SRCNN (9-5-5)
static void SRCNN955(benchmark::internal::Benchmark* b) {
  b->ArgNames(
      {"N", "H", "W", "KH", "KW", "PH", "PW", "S", "D", "G", "GCin", "GCout"});

  /*       N   H    W   KH  KW  PH  PW  S  D  G  GCin  GCout */
  b->Args({1, 384, 384, 9, 9, 0, 0, 1, 1, 1, 1, 64});
  b->Args({1, 376, 376, 5, 5, 0, 0, 1, 1, 1, 64, 32});
  b->Args({1, 372, 372, 5, 5, 0, 0, 1, 1, 1, 32, 1});
}
#define BENCHMARK_CONVOLUTION(conv_fn)                                     \
  BENCHMARK_CAPTURE(conv_fn, mobilenet_v1, "MobileNet v1")                 \
      ->Apply(MobileNetV1)                                                 \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, mobilenet_v2, "MobileNet v2")                 \
      ->Apply(MobileNetV2)                                                 \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, mobilenet_v3_small, "MobileNet v3 Small")     \
      ->Apply(MobileNetV3Small)                                            \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, mobilenet_v3_large, "MobileNet v3 Large")     \
      ->Apply(MobileNetV3Large)                                            \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v1_g1, "ShuffleNet v1 (1 group)")  \
      ->Apply(ShuffleNetV1G1)                                              \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v1_g2, "ShuffleNet v1 (2 groups)") \
      ->Apply(ShuffleNetV1G2)                                              \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v1_g3, "ShuffleNet v1 (3 groups)") \
      ->Apply(ShuffleNetV1G3)                                              \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v1_g4, "ShuffleNet v1 (4 groups)") \
      ->Apply(ShuffleNetV1G4)                                              \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v1_g8, "ShuffleNet v1 (8 groups)") \
      ->Apply(ShuffleNetV1G8)                                              \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v2_x05, "ShuffleNet v2 0.5X")      \
      ->Apply(ShuffleNetV2X05)                                             \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v2_x10, "ShuffleNet v2 1.0X")      \
      ->Apply(ShuffleNetV2X10)                                             \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v2_x15, "ShuffleNet v2 1.5X")      \
      ->Apply(ShuffleNetV2X15)                                             \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, shufflenet_v2_x20, "ShuffleNet v2 2.0X")      \
      ->Apply(ShuffleNetV2X20)                                             \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, squeezenet_v10, "SqueezeNet 1.0")             \
      ->Apply(SqueezeNetV10)                                               \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, squeezenet_v11, "SqueezeNet 1.1")             \
      ->Apply(SqueezeNetV11)                                               \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, inception_v3, "Inception v3")                 \
      ->Apply(InceptionV3)                                                 \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, resnet18, "ResNet-18")                        \
      ->Apply(ResNet18)                                                    \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, resnet50, "ResNet-50")                        \
      ->Apply(ResNet50)                                                    \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, vgg, "VGG")->Apply(VGG)->UseRealTime();       \
  BENCHMARK_CAPTURE(conv_fn, srcnn915, "SRCNN (9-1-5)")                    \
      ->Apply(SRCNN915)                                                    \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, srcnn935, "SRCNN (9-3-5)")                    \
      ->Apply(SRCNN935)                                                    \
      ->UseRealTime();                                                     \
  BENCHMARK_CAPTURE(conv_fn, srcnn955, "SRCNN (9-5-5)")                    \
      ->Apply(SRCNN955)                                                    \
      ->UseRealTime();
